package com.daisuxia.back.utils;

import com.alibaba.fastjson.JSONObject;

public class JxlUtils {
	public final  static String org_name="yangyue";
	public final  static String client_secret="de07c40f56004ac4a7a7dc3bfaba9f88";
	public final  static String hours="24";
	
	
	private final  static String src="https://www.juxinli.com/api/v2/access_report_token?client_secret="+client_secret+"&hours="+hours+"&org_name="+org_name;
	//获取access_report_token
	public static String getAccessReportToken() throws Exception {
		String rt=WebClient.getInstance().doGet(src);
		JSONObject jsONObject=	JSONObject.parseObject(rt);
		rt=(String) jsONObject.get("access_token");
		return rt;
		
	}
	
	public static void main(String[] args) throws Exception {
		
		String rt=JxlUtils.getAccessReportToken();
		System.out.println(rt);
		
	}

}
